#assumes rows do not contain label
function [result confidence] = maxCredibilityAnswer(rows, cm, handicap=0.008)
	result=zeros(size(rows,1),1);
	confidence=[];
	credibilities = zeros(size(rows));
	for(row=1:size(rows,1))
		for(classifier=1:size(rows,2))
			credibilities(row,classifier)=cm(rows(row,classifier)+1,classifier);
		end;
	end;
	for(i=1:size(rows,1))
		scores=zeros(10,1);
		[maxCr maxP] = max(credibilities(i,:));
		confCr = max(credibilities(i,rows(i,:)!=rows(i,maxP)));
		if(maxCr-confCr>handicap)
			
			result(i,1)=rows(i,maxP);
			confidence=[confidence;1];
			continue;
		
		else
			for(j=1:size(credibilities,2))
				if(credibilities(i,j)!=0)
					scores(rows(i,j)+1)+=credibilities(i,j);
				end;
			end;
		end;

		
		[value cell] = max(scores,[],1);
		
		confidence=[confidence;value/sum(scores)];
		result(i,1)=(cell-1);
	end;
end;
